/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.latesis.bean;

import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

/**
 *
 * @author Alan -  Desarrollo
 */
@Entity
@Table(name = "TBL_PUNTO_GEOCERCA")
public class PuntoGeocercaBean implements Serializable{
    
    private long id;        
    private Integer orden;
    private Double latitud;    
    private Double longitud;    
    private ZonaBean zona;
    

    @Id
    @GeneratedValue(strategy=GenerationType.IDENTITY)
    public long getId() {
        return id;
    }

    @Column(name="latitud",nullable = false)
    public Double getLatitud() {
        return latitud;
    }

    @Column(name="longitud",nullable = false)
    public Double getLongitud() {
        return longitud;
    }

    @ManyToOne(optional = false, fetch = FetchType.LAZY)
    @JoinColumn(name="zonaId")
    public ZonaBean getZona() {
        return zona;
    }
    
    @Column(name="orden",nullable = false)
    public Integer getOrden() {
        return orden;
    }

    public void setId(long id) {
        this.id = id;
    }

    public void setLatitud(Double latitud) {
        this.latitud = latitud;
    }

    public void setLongitud(Double longitud) {
        this.longitud = longitud;
    }

    public void setZona(ZonaBean zona) {
        this.zona = zona;
    }    

    public void setOrden(Integer orden) {
        this.orden = orden;
    }
    
    

}
